package org.wuxinshui.boosters.designPatterns.strategy.demo2;

/**
 * 构造方法注入
 */
public class MathStrategyContext {
    private MathStrategy strategy;


    public MathStrategyContext(MathStrategy strategy) {
        this.strategy = strategy;
    }


    public int executeStratgey(int a, int b) {
        return strategy.doOperation(a, b);
    }


}
